package com.ruoyi.common.utils.jsch;

public class JschResult {
    private int exitStatus;
    private String errOutput;
    private String msgOutput;

    public JschResult(int retCode, String msg) {
        this.exitStatus = retCode;
        if(retCode == 0)
            this.msgOutput = msg;
        else
            this.errOutput = msg;
    }

    public static JschResult build(int exitStatus,String msg){
        return new JschResult(exitStatus,msg);
    }

    public int getExitStatus() {
        return exitStatus;
    }

    public String getErrOutput() {
        return errOutput;
    }

    public String getMsgOutput() {
        return msgOutput;
    }
}
